#include "mcthread.h"

#include <process.h>

namespace MCCommon
{

static unsigned __stdcall ThreadFun( void* pVoid )
{
    MCThread* pThread = ( MCThread* )pVoid;

    if ( pThread )
    {
        pThread->Run();
    }
    
    return 0;
}

MCThread::MCThread()
{
}

MCThread::~MCThread()
{
}

void
MCThread::Start()
{
    unsigned thrdaddr;
    fThreadHandle = (HANDLE)_beginthreadex(
        NULL, 0, ThreadFun, this, 0, &thrdaddr );
}

void
MCThread::Stop()
{
}


}// end of namespace MCCommon